package jp.tkym.labs.m3d;

import java.util.List;

/**
 * Camera Object
 * @author takayama
 */
public class Camera3D{
	Translator3D translator;
	ModelDrawer modelDrawer;
	
	Camera3D(ModelingPoint3D viewPoint, DeviceTranslator device, ProjectionTranslator projection){
		this.translator = new Translator3D(
				viewPoint.coordinateModel,
				projection,
				device
				);
		this.modelDrawer = new ModelDrawer(viewPoint, this.translator);
	}
	
	public void setDeviceTranslator(DeviceTranslator device){
		translator.device = device;
	}
	
	public void setProjectionTranslator(ProjectionTranslator projection){
		translator.projection = projection;
	}
	
	public ProjectionTranslator getProjectionTranslator(){
		return translator.projection;
	}
	
	public DeviceTranslator getDeviceTranslator(){
		return translator.device;
	}
	
	public List<Draw> draw(ModelConverter converter){
		return modelDrawer.draw(converter);
	}
}